//
//  ViewController.m
//  9-20
//
//  Created by mac on 16/9/20.
//  Copyright © 2016年 mac. All rights reserved.
//

#import "ViewController.h"
#import "TableViewController.h"
@interface ViewController ()
@property (strong, nonatomic) IBOutlet UITextField *text1;
@property (strong, nonatomic) IBOutlet UITextField *text2;

@end

@implementation ViewController
- (IBAction)onClick:(UIButton *)sender
{
//    if([self.text1.text isEqualToString:@"123456789"]&&[self.text2.text isEqualToString:@"123"])
//    {
//        UIViewController *tableView = [self.storyboard instantiateViewControllerWithIdentifier:@"tabbar"];
//        [self.navigationController pushViewController:tableView animated:YES];
//        
//    }
//    else
//    {
//        UIAlertController *alert = [UIAlertController alertControllerWithTitle:@"提示" message:@"账号或密码错误" preferredStyle:UIAlertControllerStyleAlert];
//        [alert addAction:[UIAlertAction actionWithTitle:@"确认" style:UIAlertActionStyleDefault handler:nil]];
//        [self presentViewController:alert animated:YES completion:nil];
//    }
}

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
    self.text1.clearButtonMode = UITextFieldViewModeWhileEditing;
    self.text2.clearButtonMode = UITextFieldViewModeWhileEditing;
    self.text2.secureTextEntry = YES;
    self.text1.text = @"123456789";
    self.text2.text = @"123";
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
